<template>
  <div>
  <el-row class="panel-group">
    <el-col style="width: 25%;">
      <el-container >
      <div class="card-panel" @click="routeGovernment" style="border: #FBF8FF">
        <div class="card-panel-icon-wrapper icon-message">
          <i class="el-icon-warning"  style="font-size: 48px;color:#ff0000" ></i>
        </div>
        <div class="card-panel-description">
          <div class="card-panel-text">
            政府部门
          </div>
          <div class="card-panel-ser">
            云服务
          </div>
        </div>
      </div>
      </el-container>
    </el-col>

    <el-col style="width: 25%">
      <el-container >
      <div class="card-panel" @click="routeCheck">
        <div class="card-panel-icon-wrapper icon-money">
          <i class="el-icon-success"  style="font-size: 48px;color:#009bfe" ></i>
        </div>
        <div class="card-panel-description">
          <div class="card-panel-text">
            检验机构
          </div>
          <div class="card-panel-ser">
            云服务
          </div>
        </div>
      </div>
      </el-container>
    </el-col>

    <el-col style="width: 25%" >
      <el-container >
      <div class="card-panel" @click="routeProduction">
        <div class="card-panel-icon-wrapper icon-message">
          <!--<svg-icon icon-class="warning" class-name="card-panel-icon" />-->
          <i class="el-icon-s-help"  style="font-size: 48px;color:#3cc9c5" ></i>
        </div>
        <div class="card-panel-description">
          <div class="card-panel-text">
            制造单位
          </div>
          <div class="card-panel-ser">
            云服务
          </div>
        </div>
      </div>
      </el-container>
    </el-col>
    <el-col style="width: 25%">
      <el-container >
      <div class="card-panel" @click="routeUsing">
        <div class="card-panel-icon-wrapper icon-money">
          <i class="el-icon-s-custom"  style="font-size: 48px;color:#c357de" ></i>
        </div>
        <div class="card-panel-description">
          <div class="card-panel-text">
            使用单位
          </div>
          <div class="card-panel-ser">
            云服务
          </div>
        </div>
      </div>
      </el-container>
    </el-col>
  </el-row>
  </div>
</template>

<script>
import CountTo from 'vue-count-to'
import ElContainer from "element-ui/packages/container/src/main";

export default {
  components: {
    ElContainer,
    CountTo
  },
  methods: {
    routeGovernment(e) {
      this.$router.push({ path: '/service/governmentPage' })
    },
    routeCheck(e) {
      this.$router.push({ path: '/service/checkPage' })
    },
    routeUsing(e) {
      this.$router.push({ path: '/service/usingPage' })
    },
    routeProduction(e) {
      this.$router.push({ path: '/service/productionPage' })
    }
  }
}
</script>

<style lang="scss" scoped>
.panel-group {
  margin-top: 24px;
  margin-left: 5px;
  .card-panel-col {
    margin-bottom: 32px;
  }

  .card-panel {
    height: 108px;
    cursor: pointer;
    font-size: 12px;
    position: relative;
    overflow: hidden;
    color: #666;
    box-shadow: 4px 4px 40px rgba(0, 0, 0, .05);
    border-color: #ff00ff;


    &:hover {
      .card-panel-icon-wrapper {
        color: #fff;
      }

      .icon-people {
        background: #40c9c6;
      }

      .icon-message {
        background: #36a3f7;
      }

      .icon-money {
        background: #f4516c;
      }

      .icon-shopping {
        background: #34bfa3
      }
    }
    .icon-warning{
      background: #34bfa3;
    }
    .icon-people {
      color: #40c9c6;
    }

    .icon-message {
      color: #36a3f7;
    }

    .icon-money {
      color: #f4516c;
    }

    .icon-shopping {
      color: #34bfa3
    }

    .card-panel-icon-wrapper {
      float: left;
      margin: 14px 0 0 14px;
      padding: 16px;
      transition: all 0.38s ease-out;
      border-radius: 6px;
    }

    .card-panel-icon {
      float: left;
      font-size: 48px;
    }

    .card-panel-description {
      float: right;
      font-weight: bold;
      margin: 26px;
      margin-left: 0px;

      .card-panel-text {
        line-height: 30px;
        color: #ffffff;
        font-size: 36px;
        margin-bottom: 14px;
        margin-left: 120px;
      }

      .card-panel-ser {
        font-size: 30px;
        margin-left: 145px;
      }
    }
  }
}

@media (max-width:550px) {
  .card-panel-description {
    display: none;
  }

  .card-panel-icon-wrapper {
    float: none !important;
    width: 100%;
    height: 100%;
    margin: 0 !important;

    .svg-icon {
      display: block;
      margin: 14px auto !important;
      float: none !important;
    }
  }
}
</style>
